<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
    
    <%
		String path = request.getContextPath();
		String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
	%>
    
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
 <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">


    <title></title>
    <meta name="keywords" content="">
    <meta name="description" content="">
    <!--bootstrap.min.css-->
    <link href="https://cdn.bootcss.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet">
    <!--font-awesome.css?v=4.4.0-->
    <link href="https://cdn.staticfile.org/font-awesome/4.4.0/css/font-awesome.css?v=4.4.0" rel="stylesheet">
    <!--bootstrap.min.css-->
    <link href="https://cdn.bootcss.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet">
    <!--custom.css-->
	<link rel="stylesheet" type="text/css" href="<%=basePath%>css/plugins/iCheck/custom.css"/>
	<!--style.css-->
	<link rel="stylesheet" type="text/css" href="<%=basePath%>css/style.css"/>
<style>
			.top{
				width: 600px;
				height: 30px;
				background: gainsboro;
				padding-left: 10px;
			}
			.body{
				width:300px;
				height: 60px;
				background-color: #999;
				float: left;
				
			}
			div{
				float: left;
			}
			.left{
				margin-top: 13px;
				margin-left: 20px;
				
			}
			.right{
				margin-top: 13px;
				
			}
			.footer{
				width: 600px;
				height: 50px;
				background: gainsboro;
				
			}
			.footer_left{
				width: 150px;
				float: left;
				padding: 30px;
				padding-top: 0px;
				
			}
			.footer_right{
				width: 150px;
				flex: left;
				padding: 30px;
				padding-top: 0px;
				
			}
			.btn-primary{
				width: 80px;
			}
			.btn-success{
				width: 80px;
			}
		</style>
</head>
<body>
<div id="" class="top">
			<h5>充值中心</h5>
		</div>
		<form action="${pageContext.request.contextPath}/User_tableServlet/edit">
		<div class="body">
			<div id="" class="left">
				<input type="button"  class="btn btn-primary pull-right" value="会员编号">
			</div>
			<div id="" class="right">
				<div class="pull-right search"><input readonly name="user_id" id="user_id" style="height: 34px;"type="text" value=""></div>
			</div>
		</div>
		<div class="body">
			<div id="" class="left">
				<input type="button"  class="btn btn-primary pull-right" value="余额">
			</div>
			<div id="" class="right">
				<div class="pull-right search"><input readonly name="user_money" id="user_money" style="height: 34px;"type="text" value=""></div>
			</div>
		</div>
		<div class="body">
			<div id="" class="left">
				<input type="button"  class="btn btn-primary pull-right" value="充值金额">
			</div>
			<div id="" class="right">
				<div class="pull-right search"><input name="money" id="money" style="height: 34px;"type="text" placeholder="请输入充值金额"></div>
			</div>
		</div>
		<div id="" class="footer">
			<div id="" class="footer_left">
				<input  onclick="TransitionEvent" class="btn btn-success pull-right cz" type="button" value="确认充值" />
			</div>
			<div id="" class="footer_right">
				<input class="btn btn-success pull-right fh"  type="button" value="返  回" />
			</div>
		</div>
		</form>
	<!--jquery.min.js-->
<script src="https://cdn.staticfile.org/jquery/2.1.4/jquery.min.js"></script>
<!--bootstrap.min.js-->
<script src="https://cdn.bootcss.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
<!--jquery.peity.min.js-->
<script src="<%=basePath%>js/plugins/peity/jquery.peity.min.js" type="text/javascript" charset="utf-8"></script>
<!--content.js-->
<script src="<%=basePath%>js/content.js" type="text/javascript" charset="utf-8"></script>
<!--icheck.min.js-->
<script src="<%=basePath%>js/plugins/iCheck/icheck.min.js" type="text/javascript" charset="utf-8"></script>
<!--peity-demo.js-->
<script src="<%=basePath%>js/demo/peity-demo.js" type="text/javascript" charset="utf-8"></script>
<!--layer.min.js-->
<script src="<%=basePath%>js/plugins/layer/layer.min.js" type="text/javascript" charset="utf-8"></script>
<!--pagination.min.js-->
<script src="<%=basePath%>js/plugins/jquery-bootstrap-pagination/jquery-bootstrap-pagination.js" type="text/javascript"></script>
</body>
<script type="text/javascript">
	$.get('${pageContext.request.contextPath}/User_tableServlet/preChongZhi',{"user_id":${param.user_id}},function(data){
	 	var member = JSON.parse(data);
		$('#user_id').val(member.user_id);
		$('#user_money').val(member.user_money); 
	});
	
	
	$('.fh').click(function(){
		parent.layer.closeAll();
	});
	$('.cz').click(function(){
		$.get('${pageContext.request.contextPath}/User_tableServlet/edit',{"user_id":$('#user_id').val(),"user_money":$('#user_money').val(),"money":$('#money').val()},function(data){
			if(data==1){
				parent.$('#panduan').val(1);
				parent.$('#huiyuan').val($('#user_id').val());
				parent.layer.closeAll();
			}else{
				parent.$('#panduan').val(0);
				parent.layer.closeAll();
			}
		});
		
	});
	
</script>
</html>